<%- include header%>
<ul class="archive">
    <% var lastYear = 0%>
    <% posts.forEach(function (post, index) { %>
        <% if(lastYear != post.time.year) {%>
            <li><h3><%= post.time.year%></h3></li>
            <% lastYear = post.time.year %>
        <%}%>
        <li><time><%= post.time.day%></time></li>
        <li><a href="/p/<%= post._id%>"><%=post.title%></a></li>
    <%})%>
</ul>